﻿<%@ Page Language="C#" EnableViewStateMac="false" MasterPageFile="~/public_page/master_page_common1.master"  AutoEventWireup="true" CodeFile="fill_power.aspx.cs" Inherits="pay_express_fill_power" %>

<asp:Content ID="Content3" ContentPlaceHolderID="CPH_Right" runat="Server">
    <script type="text/javascript">
        function check_input(){
            var PayMoney = document.getElementById("<%=TexPayMoney.ClientID %>").getAttribute("value");       
            var MNBR = document.getElementById("<%=HidMNBR.ClientID %>").getAttribute("value");
            var WNBR = document.getElementById("<%=HidWNBR.ClientID %>").getAttribute("value");     
            var re = /^[0-9]+.?[0-9]*$/;   //判断字符串是否为数字  
            if(PayMoney == null || PayMoney == ""){
                    alert("请输入支付金额");
                    return false;
            }else if(PayMoney < 10){
                    alert("缴费金额不能低于10元");
                    return false;       
            }else if(!re.test(PayMoney)){                                               
                       alert("请输入数字(例:10.02)");                              
                       return false;   
            }else if(Number(PayMoney) < (Number(MNBR) + Number(WNBR))){ 
                       alert("充值金额不能少于应付金额和违约金额之和");
                       return false;
            }else{
                            var maxMoney;
		                    maxMoney = 500;
		                    var handle;
		                    handle = 1.5;
		                    var handleMoney = PayMoney*handle/100;
		                    if(PayMoney>maxMoney)
		                    {
		                        return confirm("温馨提示：电费缴费超过"+maxMoney+"元需收取"+handle+"%的手续费,是否继续？\r\n缴费金额:"+PayMoney+"元，手续费:"+handleMoney);
		                    }
		                    else
		                    {
		                        return true;
		                    }		                  
                        return false;
            }            
            return false;
   }    
    </script>
    <!--右边内容begin-->
    <div class="crumbs">
        您的位置： <a href="#">付费直通车</a><span>&gt;</span> <a href="#">电费缴费</a>
    </div>
    <div class="step-wrap four-step">
        <ol>
            <li class="first-step first-step-done"><span>1.输入账单信息</span></li>
            <li class="step-done"><span>2.确认信息</span></li>
            <li class="current"><span>3.输入支付信息</span></li>
            <li class="last-step "><span>4.支付成功</span></li>
        </ol>
    </div>
    <!--表单begin-->
    <form id="fill_power_bill_form" runat="server" >    
    <div class="apply-from">
        <fieldset>
            <legend><asp:Label ID="LabMessage" runat="server"></asp:Label></legend>
            <asp:Panel ID="PanPay" runat="server" Visible="True">                                
                 <div class="fm-item">
                    <label class="fm-label">缴费总金额：</label>
                    <asp:Label ID="LabPayMoney" runat="server"></asp:Label>
                </div>    
                <div class="fm-item">
                    <label class="fm-label">前次调尾：</label>
                    <asp:Label ID="LabPreMoney" runat="server"></asp:Label>
                </div>  
                <div class="fm-item">
                    <label class="fm-label">本次调尾：</label>
                    <asp:Label ID="LabNowMoney" runat="server"></asp:Label>
                </div>                                                                  
                             <div class="fm-item">
                                <label class="fm-label">电费流水号：</label>
                                <asp:Label ID="LabPNBR" runat="server"></asp:Label>
                            </div>
                            <div class="fm-item">
                                <label class="fm-label">电费日期：</label>
                                <asp:Label ID="LabPDTA" runat="server"></asp:Label>
                            </div>                
                            <div class="fm-item">
                                <label class="fm-label">应收金额：</label>
                                <asp:Label ID="LabMNBR" runat="server"></asp:Label>
                            </div>  
                            <div class="fm-item">
                                <label class="fm-label">违约金额：</label>
                                <asp:Label ID="LabWNBR" runat="server"></asp:Label>
                            </div> 
                            <div class="fm-item">
                                <label class="fm-label">户名：</label>
                                <asp:Label ID="LabUSNM" runat="server"></asp:Label>
                            </div>   
                            <div class="fm-item">
                                <label class="fm-label">地址：</label>
                                <asp:Label ID="LabUSAD" runat="server"></asp:Label>
                            </div>     
                            <div class="fm-item">
                                <label class="fm-label">电表号：</label>
                                <asp:Label ID="LabPWNO" runat="server"></asp:Label>
                            </div>           
                            <div class="fm-item">
                                <label class="fm-label">平起码：</label>
                                <asp:Label ID="LabPSNO" runat="server"></asp:Label>
                            </div>        
                            <div class="fm-item">
                                <label class="fm-label">平止码：</label>
                                <asp:Label ID="LabPPNO" runat="server"></asp:Label>
                            </div>     
                            <div class="fm-item">
                                <label class="fm-label">客户编号：</label>
                                <asp:Label ID="LabUSNO" runat="server"></asp:Label>
                            </div>     
                            <div class="fm-item">
                                <label class="fm-label">当前状态：</label>
                                <asp:Label ID="LabNOSA" runat="server"></asp:Label>
                            </div>        
                            <div class="fm-item">
                                <label class="fm-label">实收金额：</label>
                                <asp:Label ID="LabSSMN" runat="server"></asp:Label>
                            </div>                
                <div class="fm-item">
                    <label class="fm-label">支付金额：</label>
                    <asp:TextBox ID="TexPayMoney" runat="server"></asp:TextBox>
                </div>               
                <div class="fm-item">
                    <label class="fm-label">
                    </label>
                    <span class="btn btn-login">
                        <asp:Button ID="Button1" runat="server" Text="下一步"  OnClientClick="return check_input();"  OnClick="NextStep_Click"/>
                    </span>
                </div>
            </asp:Panel>
        </fieldset>
    </div>
    <asp:HiddenField ID="HidPNBR" runat="server" />
            <asp:HiddenField ID="HidPDTA" runat="server" />
            <asp:HiddenField ID="HidMNBR" runat="server" />
            <asp:HiddenField ID="HidWNBR" runat="server" />
            <asp:HiddenField ID="HidUSNM" runat="server" />
            <asp:HiddenField ID="HidUSAD" runat="server" />
            <asp:HiddenField ID="HidPWNO" runat="server" />
            <asp:HiddenField ID="HidPSNO" runat="server" />
            <asp:HiddenField ID="HidPPNO" runat="server" />
            <asp:HiddenField ID="HidUSNO" runat="server" />
            <asp:HiddenField ID="HidNOSA" runat="server" />
            <asp:HiddenField ID="HidSSMN" runat="server" />
                        <asp:HiddenField ID="HidCusNo" runat="server" />
            <asp:HiddenField ID="HidPreMoney" runat="server" />
            <asp:HiddenField ID="HidNowMoney" runat="server" />
            <asp:HiddenField ID="HidPayMoney" runat="server" />
    </form>
    <!--表单end-->
    <div class="help">
        <p>
            <strong>帮助信息：</strong></p>
    </div>
    <div class="notice">
        <p>
            <strong>注意事项：</strong></p>
        <p>
            1、在支付前，请确认帐单是否通过其他渠道付费，以免重复付费。</p>
        <p>
            2、如您的帐单已办理过代扣业务，该类帐单则不能通过付费通网站查询支付。</p>
        <p>
            3、仅限个人用户交纳家庭公用事业费使用。</p>
    </div>
    <!--右边内容end-->
</asp:Content>
